﻿using ComposantRefentielV2.BLL;
using ComposantReferentielV2;
using GeneralServices.Model;
using GeneralServices.ViewModel;
using System;
using System.Windows.Controls;

namespace WpfApplication1.TestComposantV2
{
    public class TestComposantRefVM : ViewModelBase, IComposantModification
    {
        #region IComposantModification<T> Membres

        void IComposantModification.AfterCreate(ref IDTO o)
        {
            
        }

        object IComposantModification.BeforeUpdate(IDTO o)
        {
            return o;
        }


        IBLLReferentiel IComposantModification.GetBLLReferentiel()
        {
            return new BLLEmballage(
                new BaseRepositoryEmballage<EMB_EMBALLAGE>(new FactoryDTOEmballage(), new Entities())) as IBLLReferentiel;
        }

        ParamExportCSV IComposantModification.GetParam()
        {
            return new ParamExportCSV();
        }

        void IComposantModification.CloseReferentielComposant(ReferentielControl control)
        {
            OnActionVMClosed(new ActionVMArgs(control, ""));
        }

        #endregion
    }
}
